﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Web;
using System.Web.UI;
using System.Web.UI.WebControls;

namespace TruongVuWebsite.Admin
{
    public partial class Admin : System.Web.UI.MasterPage
    {
        protected void Page_Load(object sender, EventArgs e)
        {
            if (Session["IsLogin"] == null || (int)Session["IsLogin"] == 0)
            {
                Response.Redirect("~/Admin/Login.aspx");
            }
        }

        protected void LogOutButton_Click(object sender, ImageClickEventArgs e)
        {
            Session["IsLogin"] = 0;
            Session["UserName"] = string.Empty;
            Response.Redirect("~/Admin/Login.aspx");
        }
    }
}